<li class="level_one_li">
               <a href="{dede:field  name='typeurl'/}" title="{dede:field name='typename'/}">{dede:field name='typename'/}</a>
                 <ul class="level_two_ul" style="">
                  {dede:sql sql='Select * from dede_arctype where reid=~id~ order by sortrank asc' }
                   <li class="level_two_li"><a href="[field:typedir function='str_replace("{cmspath}","",@me)'/]">[field:typename/]</a></li>
                  {/dede:sql} 
                </ul>
              </li>